import AoeIcon from './AoeIcon.vue';
import AoeMenu from './AoeMenu.vue';
import AoeButton from './AoeButton.vue';
import AoeForm from './AoeForm.vue';
import AoeRow from './AoeRow.vue';
import AoeTreeSelect from './AoeTreeSelect.vue';
import AoeTimeSelect from './AoeTimeSelect.vue';
import AoeTable from './AoeTable.vue';
import AoeInput from './AoeInput.vue';
import AoeBreadcrumb from './AoeBreadcrumb.vue';
import type { ThemeType } from 'aoe';
import AoeTag from './AoeTag.vue';

export { LayPopconfirm as AoePopconfirm } from '@layui/layui-vue';
export {
    // 渐变
    LayTransition as AoeTransition,
    // 布局
    LayCol as AoeCol,
    LaySpace as AoeSpace,
    LayCard as AoeCard,
    LaySplitPanel as AoeSplitPanel,
    LaySplitPanelItem as AoeSplitPanelItem,
    LayLayout as AoeLayout,
    LaySide as AoeSide,
    LayLogo as AoeLogo,
    LayHeader as AoeHeader,
    LayBody as AoeBody,
    LayFooter as AoeFooter,
    LayContainer as AoeContainer,
    LayFullscreen as AoeFullscreen,
    LayLine as AoeLine,
    // 导航
    LayTab as AoeTab,
    LayTabItem as AoeTabItem,
    LayMenuItem as AoeMenuItem,
    LaySubMenu as AoeSubMenu,
    LayDropdown as AoeDropdown,
    LayDropdownMenu as AoeDropdownMenu,
    LayDropdownMenuItem as AoeDropdownMenuItem,
    //
    LayButtonContainer as AoeButtonGroup,
    LayTooltip as AoeTooltip,
    // 工具
    LayQrcode as AoeQrcode,
} from '@layui/layui-vue';

export {
    LayFormItem as AoeFormItem,
    LaySelect as AoeSelect,
    LaySelectOption as AoeSelectOption,
    LayAutocomplete as AoeAutocomplete,
    LayCheckboxGroup as AoeCheckboxGroup,
    LayCheckbox as AoeCheckbox,
    LayColorPicker as AoeColorPicker,
    LayDatePicker as AoeDatePicker,
    LayIconPicker as AoeIconPicker,
    LayInputNumber as AoeInputNumber,
    LayRadioGroup as AoeRadioGroup,
    LayRadio as AoeRadio,
    LayRate as AoeRate,
    LaySwitch as AoeSwitch,
    LayTextarea as AoeTextarea,
} from '@layui/layui-vue';

export {
    AoeIcon,
    //
    AoeButton,
    AoeTag,
    // 布局
    AoeRow,
    // 表格
    AoeTable,
    // 表单
    AoeForm,
    AoeInput,
    AoeTreeSelect,
    AoeTimeSelect,
    // 导航
    AoeBreadcrumb,
    AoeMenu,
};

export {
    AdditionIcon,
    SubtractionIcon,
    TriangleRIcon,
    TriangleDIcon,
    UpIcon,
    DownIcon,
    AddOneIcon,
    DeleteIcon,
    MoreVerticalIcon,
    EyeInvisibleIcon,
    EyeIcon,
    LockIcon,
    SpreadLeftIcon,
    ShrinkRightIcon,
    RefreshOneIcon,
    ScreenFullIcon,
    ScreenRestoreIcon,
    MoreIcon,
    UsernameIcon,
    WebsiteIcon,
    SuccessIcon,
    ErrorIcon,
    MaleIcon,
    FemaleIcon,
} from '@layui/icons-vue';

type LayTheme = 'primary' | 'normal' | 'warm' | 'danger' | undefined;
export const prepare_theme = (theme?: ThemeType): LayTheme => {
    if (!theme) return undefined;
    switch (theme) {
        case 'primary':
            return 'normal';
        case 'danger':
            return 'danger';
        case 'warning':
            return 'warm';
        case 'success':
            return 'primary';
        default:
            return undefined;
    }
};
